package com.tdkj.model.risevalue;

import java.util.Set;

import javax.persistence.CascadeType;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.OneToMany;
import javax.persistence.Table;

import com.tdkj.model.base.BaseEntity;

/**
 * XnkyAdvert entity. @author MyEclipse Persistence Tools
 */
@Entity
@Table(name = "risevalue_advert_type")
public class BeanAdvertType extends BaseEntity implements java.io.Serializable {

	/**
	 * 
	 */
	private String name;
	
	private Set<BeanAdvert> adverts;
	/**
	 * @return the name
	 */
	public String getName() {
		return name;
	}
	/**
	 * @param name the name to set
	 */
	public void setName(String name) {
		this.name = name;
	}
	/**
	 * @return the adverts
	 */
	@OneToMany(mappedBy="type",cascade={CascadeType.REFRESH},fetch=FetchType.LAZY)
	public Set<BeanAdvert> getAdverts() {
		return adverts;
	}
	/**
	 * @param adverts the adverts to set
	 */
	public void setAdverts(Set<BeanAdvert> adverts) {
		this.adverts = adverts;
	}
	
	
	

}